package code;

import java.rmi.Naming;
import java.rmi.RemoteException;

class BanqueClient {

	public static void main(String args[]){
		
		
		try {

			BanqueInterface banque =  (BanqueInterface)Naming.lookup("rmi://localhost:1099/MaBanque");
			Compte c;
			c = banque.ouvrirCompte("Amadou","test");
			banque.deposer(10,c);
			banque.retirer(50,c);
			
			System.out.println(banque.balance(c));
			
		} catch (RemoteException e1) {
			
			e1.printStackTrace();
		}
		catch (Exception e1) {
			
			e1.printStackTrace();
		}
		
		

	}
}
